package eit.model;

import java.io.Serializable;
import java.util.ArrayList;


public class Issue implements Serializable
{
	private Integer ID ;
	private String title;
	private String description ;
	private ArrayList<Field> customFieldList;
	private ArrayList<Tag> tagList ;
	private Project project ;
	private Integer typeID ;


	public String getTypeText()
	{
		// TODO: Align to Configuration
		switch(this.typeID)
		{
			case 0:
				return "Ticket" ;			
			case 1:
				return "Incident" ;
			case 2:
				return "Problem" ;
			case 3:
				return "Request" ;
				
			default:
				return "<ERROR!>" ;
		}
	}

	public Integer getID()
	{
		return ID;
	}

	public void setID(Integer ID)
	{
		this.ID = ID;
	}

	public String getTitle()
	{
		return title;
	}

	public void setTitle(String title)
	{
		this.title = title;
	}

	public String getDescription()
	{
		return description;
	}

	public void setDescription(String description)
	{
		this.description = description;
	}

	public ArrayList<Tag> getTagList()
	{
		return tagList;
	}

	public void setTagList(ArrayList<Tag> tagList)
	{
		this.tagList = tagList;
	}

	public Project getProject()
	{
		return project;
	}

	public void setProject(Project project)
	{
		this.project = project;
	}

	public Integer getTypeID()
	{
		return typeID;
	}

	public void setTypeID(Integer typeID)
	{
		this.typeID = typeID;
	}

	public ArrayList<Field> getFieldList()
	{
		return customFieldList;
	}

	public void setFieldList(ArrayList<Field> fieldList)
	{
		this.customFieldList = fieldList;
	}
}
